<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="Windows-31J"%>
<%@taglib uri="/tags/struts-bean" prefix="bean"%>
<%@taglib uri="/tags/struts-html" prefix="html"%>
<%@taglib uri="/tags/struts-logic" prefix="logic"%>
<%@taglib uri="/tags/struts-nested" prefix="nested"%>
<html:html>
<head>
<link href="/icdecs_client/pages/css/stylebase.css" rel="stylesheet"
	type="text/css" media="all">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
<script>
	function diableAnother() {
		var mode = document.getElementsByName("mode");
		//alert(mode.item(0).value);
		var cardID = document.getElementsByName("cardID").item(0);
		var uploadFile = document.getElementsByName("uploadFile").item(0);
		//alert(mode.item(0).value);
		var input = 0;
		var csv = 1;
		if (mode.item(0).value == "csv") {
			input = 1;
			csv = 0;
		}
		if (mode.item(input).checked) {
			cardID.disabled = false;
			uploadFile.disabled = true;
		}
		if (mode.item(csv).checked) {
			cardID.disabled = true;
			uploadFile.disabled = false;
		}
	}
</script>
</head>
<body onload="diableAnother()">
	<font color="red"><html:errors /></font>
	<html:form enctype="multipart/form-data" action="/regisListAction">

		<table width="100%">
			<!-- Title -->
			<tr>
				<td>
					<table class="title" width="550" align="center">
						<tr>
							<td align="center" valign="top">
								<H1>RegisList</H1>
							</td>
						</tr>
					</table>
				</td>
			</tr>

			<!-- Body of form -->

			<tr>
				<td valign="top">
					<table width="550" align="center">
						<tr>
							<td>
								<table align="left" cellpadding="5" class="modesentaku">
									<colgroup align="left" width="300">
									<colgroup align="left" width="350">
									<tr>
										<th align="left">AuthenticationID</th>
										<td align="left"><html:text property="authenticationID"
												size="20" maxlength="8" /></td>
									</tr>
									<tr>
										<th align="left">AuthenticationKey</th>
										<td align="left"><html:text property="authenticationKey"
												size="20" maxlength="8" /></td>
									</tr>
									<tr>
										<th align="left">OrganizationID</th>
										<td align="left"><html:text property="organizationID"
												size="20" maxlength="8" /></td>
									</tr>
									<tr>
										<td colspan="2"><hr /></td>
									</tr>
								</table>
							</td>
						</tr>
						<tr>
							<td colspan="2" align="center"><h3>Input or Choice file
									list CardID</h3></td>
						</tr>
						<tr>
							<td>
								<table align="center" cellpadding="5" class="modesentaku">
									<colgroup align="left" width="300">
									<colgroup align="left" width="350">
									<tr>
										<th align="left"><html:radio onclick="diableAnother();"
												property="mode" value="input"></html:radio> CardID</th>
										<td align="left"><html:textarea indexed="3"
												property="cardID" cols="30" rows="10" /></td>
									</tr>
								</table>
							</td>
						</tr>
						<tr>
							<td>
								<table align="center" cellpadding="5" class="modesentaku">
									<colgroup align="left" width="300">
									<colgroup align="left" width="350">
									<tr>
										<th align="left"><html:radio onclick="diableAnother();"
												property="mode" value="csv"></html:radio> File :</th>
										<td align="left"><html:file property="uploadFile" /></td>
									</tr>
								</table>
							</td>
						</tr>
					</table>
				</td>
			</tr>
			<tr>
				<td colspan="2" align="center"><html:submit
						style="height:30px;width:70px;margin-top:30px;">submit</html:submit></td>

			</tr>
			<!-- end form -->

		</table>
		<bean:write name="RegisListActionForm" property="message" />
	</html:form>
</body>
</html:html>